__author__ = 'lukasz'
from katedra.Publications.models import Publication , Author
from django.template import RequestContext
from django.shortcuts import *

def publications_view(request):
    print "aaaaa"
 #   print Author.objects.select_related().all()[0].author.username
    return render_to_response('publications_view.html',
        {'pub': Author.objects.select_related().all()},
        context_instance = RequestContext(request)
    )

def publications_author_view(request):
    return render_to_response('templates/publications_view.html',
        {'publications': Author.objects.select_related()},
        context_instance = RequestContext(request)
    )


    ##def worker_detail(request):
    ##    return render_to_response('templates/worker_detail.html',
    ##    {})